class Account < ActiveRecord::Base
  belongs_to  :customer,  
              :class_name => "Party", 
              :foreign_key => :customer_id
  
  belongs_to  :billing_address,
              :class_name => "Address",
              :foreign_key  => :billing_address_id
  
  belongs_to  :shipping_address,
              :class_name => "Address",
              :foreign_key  => :shipping_address_id
              
  validates_presence_of  :customer
              
end
